package com.qdu.springboot01cache;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cache.annotation.EnableCaching;

/**
 * @Cacheable 设置缓存，能够根据方法的请求参数对其结果进行缓存
 * @CacheEvict 清除缓存
 * @CachePut 保证方法被调用，又希望结果被缓存
 * */

@SpringBootApplication
@MapperScan("com.qdu.springboot01cache.mapper")
@EnableCaching//开启基于注解的缓存
public class Springboot01CacheApplication {

    public static void main(String[] args) {
        SpringApplication.run(Springboot01CacheApplication.class, args);
    }
}
